<h2>Login Form</h2>

<form action="" method="post">
	<?php if ( $error['userid_error'] ): ?>
		<p><i>Wrong username or password</i></p>
	<?php endif; ?>
	<?php if ( $error['userid'] ): ?>
		<p><i>Username length should be 4 to 23 characters long, consisting of a-z0-9_.</i></p>
	<?php endif; ?>
	<p>Username:<br /><input type="text" name="userid" value="<?php echo htmlspecialchars($_POST['userid']); ?>"/></p>
	
	<?php if ( $error['user_pass'] ): ?>
		<p><i>Password length should be 4 to 23 characters long, consisting of a-z0-9_.</i></p>
	<?php endif; ?>
	<p>Password:<br /><input type="password" name="user_pass" /></p>
	
	<p><input type="submit" value="Login" /></p>
</form>